Skip to content

doc: finalize statements in sqlite examples - #65088

Merged
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
araujogui:sqlite-statement-teardown
Aug 8, 2026
Merged

doc: finalize statements in sqlite examples#65088
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
araujogui:sqlite-statement-teardown

Conversation

@araujogui

@araujogui araujogui commented Aug 6, 2026

Copy link
Copy Markdown
Member

The examples left prepared statements to be finalized implicitly. Use close() in the introductory example and using in the shorter ones.

Refs: #64232 (review)

Copilot AI lite review requested due to automatic review settings August 6, 2026 17:03
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Review requested:

  • @nodejs/sqlite

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Updates the SQLite API documentation examples to ensure prepared statements are properly finalized/closed, reducing the risk of leaking statement handles.

Changes:

  • Added explicit .close() calls to prepared statements in introductory examples.
  • Replaced one-liner prepare(...).get() usage with using declarations to leverage automatic disposal.
  • Updated session-related examples to use using for prepared statements.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread doc/api/sqlite.md
Comment thread doc/api/sqlite.md
Comment thread doc/api/sqlite.md
@trivikr trivikr added doc Issues and PRs related to the documentations. sqlite Issues and PRs related to the SQLite subsystem. labels Aug 7, 2026

@Renegade334 Renegade334 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

GitHub Actions turbo-died on this commit for some reason, it might be easier just to rebase.

Signed-off-by: Guilherme Araújo <arauujogui@gmail.com>
@araujogui
araujogui force-pushed the sqlite-statement-teardown branch from a5ef016 to e73c46b Compare August 7, 2026 20:10
Comment thread doc/api/sqlite.md Outdated
@araujogui
araujogui requested a review from trivikr August 8, 2026 13:49
@trivikr trivikr added commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. commit-queue Add this label to land a pull request using GitHub Actions. author ready PRs that have at least one approval, no pending requests for changes, and a CI started. labels Aug 8, 2026
@nodejs-github-bot nodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Aug 8, 2026
@nodejs-github-bot
nodejs-github-bot merged commit 862d994 into nodejs:main Aug 8, 2026
26 checks passed
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Landed in 862d994

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author ready PRs that have at least one approval, no pending requests for changes, and a CI started. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. doc Issues and PRs related to the documentations. sqlite Issues and PRs related to the SQLite subsystem.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants